package cxt.cn.springcloud.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class EchoController {
    @Value("${server.port}")
    private String serverPort;
    @RequestMapping(value = "/echo/{id}", method = RequestMethod.GET)
    public String echo(@PathVariable Long id) {
        return "Hello Nacos Discovery " +"\t"+serverPort+id.toString();
    }
}